<{include file="../modules/_manager/header.html" title='会社口座'}>

<script src="<{$ROOTPATH}>/_manager/scripts/vars/bank.js.php"></script>
<script> jQuery(function($){bank.init();}); </script>
<div class="block">
<h1>登録会社口座数：<b><{$len}></b>件</h1>
<h2><a class="typeLink" onclick="bank.todo(-1,2)">会社口座を新規作成する</a></h2>
<table class="table_list">
	<thead class="listitem">
		<tr class="header">
			<td>
				銀行
			</td>
			<td>
				支店
			</td>
			<td>
				口座
			</td>
			<td>
				名義
			</td>
			<td>
				詳細情報[4]
			</td>
			<td>
				ログインURL
			</td>
			<td>
				編集[4]
			</td>
			<td>
				削除[4]
			</td>
		</tr>
	</thead>
	<tbody class="listitem">
		<{foreach $listview as $entry}>
			<{if $entry@iteration is even by 1}>
				<tr class="iteration">
			<{else}>
				<tr>
			<{/if}>
			<td>
				<{$entry.bank}>
			</td>
			<td>
				<{$entry.branch}>
			</td>
			<td>
				<{$entry.bankno}>
			</td>
			<td>
				<{$entry.name}>
			</td>
			<td>
				<{if $login_levelno  gt 80}>
				<a class="typeLink" onclick="bank.show_passwd(<{$entry.bankId}>)">詳細表示</a>
				<{else}>
				-
				<{/if}>
			</td>
			<td>
				<{if $login_levelno  gt 50}>
				<a href="<{$entry.url}>" target="_blank" class="typeLink">ログイン</a>
				<{else}>
				-
				<{/if}>
			</td>
			<td>
				<{if $login_levelno  gt 80}>
				<a class="typeLink" onclick="bank.todo(<{$entry.bankId}>,0)">編集
				</a>
				<{else}>
				-
				<{/if}>
			</td>
			<td>
				<{if $login_levelno  gt 85}>
				<a class="typeLink" onclick="blockDesign.message( $(bank.del._name),'382px');
					$('#delete_bank_id').val('<{$entry.bankId}>');">削除</a>
				<input type="hidden" value="<{$entry.bank}>" id="admin_bank_hidden_<{$entry.bankId}>">
				<input type="hidden" value="<{$entry.branch}>" id="admin_branch_hidden_<{$entry.bankId}>">
				<input type="hidden" value="<{$entry.bankno}>" id="admin_bankno_hidden_<{$entry.bankId}>">
				<input type="hidden" value="<{$entry.name}>" id="admin_name_hidden_<{$entry.bankId}>">
				<input type="hidden" value="<{$entry.url}>" id="admin_url_hidden_<{$entry.bankId}>">
				<{else}>
				-
				<{/if}>
			</td>
		</tr>
		<{/foreach}>
	</tbody>
</table>
</div>

<div id="newbank_form" class="new_form" style="display:none;">
	<div id="newbank_form_title">業者様をを新規作成する</div>
	<div>
		<table>
			<tr>
				<td>銀行：</td>
				<td><input type="text" id="bank_bank_text" style="width:160px;"/></td>
				<td></td>
			</tr>
			<tr>
				<td>支店：</td>
				<td><input type="text" id="bank_branch_text" style="width:160px;" /></td>
				<td></td>
			</tr>
			<tr>
				<td>口座：</td>
				<td><input type="text" id="bank_bankno_text" /></td>
				<td></td>
			</tr>
			<tr>
				<td>名義：</td>
				<td><input type="text" id="bank_name_text" style="width:100px;" /></td>
				<td></td>
			</tr>
			<tr>
				<td>ログインURL：</td>
				<td><input type="text" id="bank_url_text" /></td>
				<td></td>
			</tr>
			<tr>
				<td>詳細情報[レベル4]：</td>
				<td>
				<input type="password" id="bank_important_passwd" style="width:100px">
				<a class="typeLink" id="bank_important_link" onclick="bank.load_important()">ログイン情報を修正する</a>
				<textarea id="bank_important_text" cols="25" rows="5"></textarea></td>
				<td></td>
			</tr>
		</table>
		<a class="typeLink" id="newbank_form_ok" onclick="if($('#bank_id_hidden').val()==0)  
			bank.add(); else  bank.update();">新規作成</a>
	 	<a class="typeLink" onclick="$.unblockUI();">Close</a>
	 	<input type="hidden" id="bank_id_hidden" value="0">
	 	<input type="hidden" id="bank_important_change_hidden" value="0">
	</div>
</div>
<div class="new_form" id="important_form" style="display: none;">
	<div>ログイン情報を表示する</div>
	<div>
		<table>

			<tr id="important_tr_passwd">
				<td>Adminパスワード:</td>
				<td><input type="password" id="bank_important_passwd1" style="width:100px">
					<a class="typeLink" onclick="bank.show_important()">暗証番号</a>
				</td>
			</tr>
			<tr id="important_view" style="display: none;">
				<td colspan="2">
				</td>
			</tr>
			<tr>
				<td>
					<a class="typeLink" onclick="$.unblockUI();">Close</a>
					<input type="hidden" id="bank_id_hidden1" value="0"></td>
				<td></td>
			</tr>
		</table>
	</div>
</div>
<{if $login_adminId == 1}>
<div id="delbank_form" class="new_form" style="display: none;">
    <div>
        会社口座を削除されます。<br />
        削除しますか？
    </div>
    <div>
        <a class="typeLink" onclick="bank.todo(-1,1)">削除する</a> <a class="typeLink" onclick="$.unblockUI();">
            キャンセル</a>
    </div>
    <input type="hidden" id="delete_bank_id" value="" />
</div>
<{/if}>

<{include file="../modules/_manager/footer.html"}>









